from django.urls import path

from app.ctrl.app import tbk, tbk_auth, tbk_view, test


def build_path(_path, ctrl, group='app'):
    _p = '{}/{}'.format(group, _path)
    return path(_p, ctrl)


urlpatterns = [
    build_path('dg_optimus_material', tbk.dg_optimus_material),
    build_path('dg_material_optional', tbk.dg_material_optional),
    build_path('tbk_query_goods', tbk.query_goods),
    build_path('tbk_auth_callback', tbk_auth.callback),
    build_path('tbk_bind_member', tbk_auth.bind_member),
    build_path('tbk_goods_list', tbk_view.goods_list),
    build_path('tbk_rebate_order_get', tbk.rebate_order_get),
    build_path('get_token', test.get_token),
]
